<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>欢迎页面</title>
<style>
    body {
        font-family: Arial, sans-serif;
        background-color: #f4f4f9;
        color: #333;
        margin: 0;
        padding: 0;
        text-align: center;
    }
    h1 {
        color: #4CAF50;
        margin-top: 20px;
    }
    a {
        display: inline-block;
        margin: 10px;
        padding: 10px 20px;
        background-color: #4CAF50;
        color: white;
        text-decoration: none;
        border-radius: 5px;
    }
    a:hover {
        background-color: #45a049;
    }
    .container {
        margin: 20px auto;
        width: 80%;
        max-width: 600px;
    }
    .section {
        margin-bottom: 20px;
    }
    .section h2 {
        color: #333;
    }
    .section a {
        margin: 5px;
    }
	@media (max-width: 600px) {
    .container {
        width: 90%;
    }
    a {
        width: 100%;
        box-sizing: border-box;
        margin-bottom: 10px;
    }
}

</style>
</head>
<body>
<%
request.setCharacterEncoding("UTF-8");

%>
<%
String username="";
Cookie[] cks=request.getCookies();
if(cks!=null)
{
	for(Cookie a:cks)
	{
		if(a.getName().equals("username")){
			username=a.getValue();
		}
	}
}
%>
<div class="container">
    <h1>登录成功！欢迎您！<%=username %></h1>
    <div class="section">
        <h2>用户管理</h2>
        <a href="selectUserAll.jsp">查询所有用户</a>
        <br>
        <a href="SelectUserByUname.jsp">按用户名查询</a>
        <a href="SelectUserByRname.jsp">按真实姓名查询</a>
        <br>
        <a href="UpdateUserByUname.jsp">按用户名修改</a>
        <a href="">按序号修改</a>
        <br>
        <a href="DeleteUserByUname.jsp">按用户名删除</a>
        <a href="">按序号删除</a>
    </div>
    <div class="section">
        <h2>商品管理</h2>
        <a href="selectProductDiscount.jsp">查询有折扣的商品</a>
        <br>
        <a href="SelectProductByArea.jsp">按商品产地查询</a>
        <a href="SelectProductByName.jsp">按商品名称查询</a>
        <br>
        <a href="UpdateProductById.jsp">按商品序号修改</a>
    </div>
</div>
</body>
</html>
